package scenes;

import awe6.interfaces.EScene;
import awe6.interfaces.IKernel;
import nme.Assets;
import nme.display.Bitmap;

import entities.Start;

/**
 * ...
 * @author Andrew Ekeren
 */

class Intro extends AScene {
	
	
	private var _start:Start;
	
	
	public function new ( _kernel:IKernel, type:EScene ) {
		
		_session = cast _kernel.session;
		
		super ( _kernel, type, true, true, true );
		
	}
	
	
	override private function _init():Void {
		
		super._init();
		
		trace ( "Entering Intro" );
		
		// extend / addentities
		
		_title.text = "INTRO"; 
		
		_start = new Start ( _kernel );
		addEntity ( _start );
		
		var test = new Bitmap (Assets.getBitmapData ("assets/graphics/wabbit_alpha.png"));
		var TestEntity = _kernel.factory.createEntity ("TestEntity");
		
	}
	
	
	
	
	
	// Entry point
	
	
	
	
	
	override private function _updater( ?p_deltaTime:Int = 0 ):Void {
		
		super._updater( p_deltaTime );
		
		// example:
		if ( _kernel.inputs.keyboard.getIsKeyRelease( _kernel.factory.keyNext ) ) {
			
			_kernel.scenes.next();
			
		}
		
	}
	
}
